//
//  LAGClusterAnnotation+LAGAnnotationExt.m
//  LAMapBasicDemo
//
//  Created by 罗亮富 on 2017/7/3.
//  Copyright © 2017年 2Bulu. All rights reserved.
//

#import "LAGClusterAnnotation+LAGAnnotationExt.h"

@implementation LAGClusterAnnotation (LAGAnnotationExt)

-(MKAnnotationView *)createAnnotationview
{
    MKAnnotationView *v;
    id<LAGAnnotationExt> an = (id<LAGAnnotationExt>)self.frontChildAnnotation;
    if([an respondsToSelector:@selector(createAnnotationview)])
        v = [an createAnnotationview];
    
//    if(v)
//    {
//        v.backgroundColor = [UIColor redColor];
//        
//    }
    return v;
}

-(NSString *)viewReuseIdentifer
{
    NSString *reuseId = nil;
    id<LAGAnnotationExt> an = (id<LAGAnnotationExt>)self.frontChildAnnotation;
    if([an respondsToSelector:@selector(viewReuseIdentifer)])
        reuseId = [an viewReuseIdentifer];
    
    return reuseId;
}

@end
